<template>
  <div class="not-found-container">
    <el-result
      icon="warning"
      title="404"
      sub-title="抱歉，您访问的页面不存在"
    >
      <template #extra>
        <el-button type="primary" @click="$router.push('/home')">
          回到首页
        </el-button>
        <el-button @click="$router.go(-1)">
          返回上一页
        </el-button>
      </template>
    </el-result>
  </div>
</template>

<script>
import { onMounted } from 'vue'
import { useStore } from 'vuex'

export default {
  name: 'NotFound',
  setup() {
    const store = useStore()
    
    onMounted(() => {
      store.dispatch('setPageTitle', '页面未找到')
    })
  }
}
</script>

<style scoped>
.not-found-container {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
}
</style> 